<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ include file="../base.jsp"%>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Login</title>
    <!-- 引入 Bootstrap CSS -->
    <link href="..${ctx}/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet">
    <style>
        body {
            background-color: #f8f9fa;
            display: flex;
            justify-content: center;
            align-items: center;
            height: 100vh;
            margin: 0;
        }
        .login-container {
            background-color: #fff;
            padding: 20px;
            border-radius: 8px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
            width: 300px;
        }
        .login-container h2 {
            text-align: center;
            margin-bottom: 20px;
        }
        .login-container form {
            display: flex;
            flex-direction: column;
        }
        .login-container form .form-group {
            margin-bottom: 15px;
        }
        .login-container form .form-group label {
            margin-bottom: 5px;
        }
        .login-container form .form-group input {
            padding: 10px;
            border: 1px solid #ccc;
            border-radius: 4px;
        }
        .login-container form .form-group button {
            padding: 10px;
            background-color: #007bff;
            border: none;
            color: #fff;
            border-radius: 4px;
            cursor: pointer;
        }
        .login-container form .form-group button:hover {
            background-color: #0056b3;
        }
        .error-message {
            color: red;
            text-align: center;
            margin-top: 10px;
        }
    </style>
</head>
<body>
<div class="login-container">
    <h2>登录系统</h2>
    <form action="${ctx}/login.do" method="post">
        <div class="form-group">
            <label for="username">用户邮箱</label>
            <input type="text" id="username" value="lw@export.com" name="username" class="form-control" required>
        </div>
        <div class="form-group">
            <label for="password">密码</label>
            <input type="password" id="password" value="123456" name="password" class="form-control" required>
        </div>
        <div class="form-group">
            <button type="submit" class="btn btn-primary">Login</button>
        </div>
    </form>
    <c:if test="${not empty message}">
        <div class="error-message">${message}</div>
    </c:if>
</div>
<!-- 引入 Bootstrap JS -->
<script src="..${ctx}/plugins/bootstrap/js/bootstrap.min.js"></script>
</body>
</html>